package com.qfedu.provider.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;

/**
 * 用户详情日志
 * @TableName db_userdetail_log
 */
@TableName(value ="db_userdetail_log")
@Data
public class DbUserdetailLog implements Serializable {
    /**
     * 主键
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 用户id
     */
    @TableField(value = "user_id")
    private Integer userId;

    /**
     * 操作人ip
     */
    @TableField(value = "ip")
    private String ip;

    /**
     * 操作类型
     */
    @TableField(value = "comment")
    private String comment;

    /**
     * 创建时间
     */
    @TableField(value = "create_time")
    private Date createTime;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    public DbUserdetailLog(Integer userId, String ip, String comment) {
        this.userId = userId;
        this.ip = ip;
        this.comment = comment;
        this.createTime = new Date();
    }
}